package main

import (
	"fmt"
	"time"
)

func main() {
	//a := 0
	//switch a {
	//case 1:
	//	fmt.Printf("aaaaaaaaa")
	//	return
	//}
	//fmt.Printf("bbbbbbbb")

	s := "a"
	for {
		switch s {
		case "a":
			fmt.Println("s1")
			s = "b"
			time.Sleep(1 * time.Second)
		case "b":
			fmt.Println("s2")
			s = "c"
			time.Sleep(2 * time.Second)
		case "c":
			fmt.Println("s3")
			time.Sleep(2 * time.Second)
			break
		}
	}
	//
	//OutLoop:
	//	for {
	//		switch s {
	//		case "a":
	//			fmt.Println("s1")
	//			s = "b"
	//			time.Sleep(1 * time.Second)
	//			break
	//		case "b":
	//			fmt.Println("s2")
	//			s = "c"
	//			time.Sleep(2 * time.Second)
	//		case "c":
	//			fmt.Println("s3")
	//			time.Sleep(2 * time.Second)
	//			break OutLoop
	//		}
	//	}

}
